]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
authPrompt: Do not allow bypassing disabled Sign In button
authorMichael Catanzaro <mcatanzaro@igalia.com>
Thu, 7 Jan 2016 22:03:41 +0000 (16:03 -0600)
committerMichael Catanzaro <mcatanzaro@igalia.com>
Thu, 7 Jan 2016 23:19:04 +0000 (17:19 -0600)
The Next and Sign In buttons are disabled when the username/password
field is empty. However, the user can still bypass this button by
pressing the enter key, leading to some odd glitches with the log in
for 'Not Listed?' users.

This is easy to fix by simply not progressing to the next screen when
the button is disabled.

https://bugzilla.gnome.org/show_bug.cgi?id=746180

js/gdm/authPrompt.js

index 88ed2a6890831c63d83cf4f7d64421e5481ee036..50c66fd13deff55df90546662396a29ce873b92e 100644 (file)
@@ -189,7 +189,8 @@ const AuthPrompt = new Lang.Class({
                                              this._updateNextButtonSensitivity(this._entry.text.length > 0);
                                          }));
         this._entry.clutter_text.connect('activate', Lang.bind(this, function() {
-            this.emit('next');
+            if (this.nextButton.reactive)
+                this.emit('next');
         }));
     },